﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace SimpleTaskManager.Domain.Entities
{
    /// <summary>
    /// The class to represent a task
    /// </summary>
    public class Task
    {
        /// <summary>
        /// ID field
        /// </summary>
        public int TaskID { get; set; }

        /// <summary>
        /// The name of the task
        /// </summary>
        public string Name { get; set; }

        /// <summary>
        /// The leader of the task
        /// </summary>
        public User Leader { get; set; }

        /// <summary>
        /// The collection which represents the people in the task
        /// <remarks>The type probably will be changed to something else (DbSet<User>?)</remarks>
        /// </summary>
        public IEnumerable<User> Group { get; set; }

        public IEnumerable<Task> SubTasks { get; set; }

        public DateTime StartDate { get; set; }

        public DateTime EndDate { get; set; }

        public TaskStatusEnum Status { get; set; }

        public int Rating { get; set; }

        public string Description { get; set; }
    }

    public enum TaskStatusEnum {New, Rejected, Pending, InProgress, Failed, Finished}
}